package pers.cj.pdos.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;
import pers.cj.pdos.entity.HouseIn;
import pers.cj.pdos.entity.HouseInGoods;
import pers.cj.pdos.vo.HouseInVo;
import pers.cj.pdos.vo.HouseWaitInVo;

import java.util.Date;
import java.util.List;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author chenj
 * @since 2020-01-14
 */
public interface HouseInMapper extends BaseMapper<HouseIn> {
    List<HouseInVo> listVo(@Param("companyId") String companyId,
                           @Param("page") Integer page,
                           @Param("limit") Integer limit,
                           @Param("close") Boolean close,
                           @Param("type") Integer type,
                           @Param("search") String search,
                           @Param("no") String no,
                           @Param("linkNo") String linkNo,
                           @Param("goodsName") String goodsName,
                           @Param("remark") String remark,
                           @Param("unitName") String unitName,
                           @Param("makeTime1") Date makeTime1,
                           @Param("makeTime2")Date makeTime2,
                           @Param("makeUserId") String makeUserId,
                           @Param("userStoreId") String userStoreId,
                           @Param("userId") String userId,
                           @Param("date1")Date date1,
                           @Param("date2")Date date2,
                           @Param("storeId") String storeId,
                           @Param("houseId") String houseId);

    Long count(@Param("companyId") String companyId,
               @Param("close") Boolean close,
               @Param("type") Integer type,
               @Param("search") String search,
               @Param("no") String no,
               @Param("linkNo") String linkNo,
               @Param("goodsName") String goodsName,
               @Param("remark") String remark,
               @Param("unitName") String unitName,
               @Param("makeTime1") Date makeTime1,
               @Param("makeTime2")Date makeTime2,
               @Param("makeUserId") String makeUserId,
               @Param("userStoreId") String userStoreId,
               @Param("userId") String userId,
               @Param("date1")Date date1,
               @Param("date2")Date date2,
               @Param("storeId") String storeId,
               @Param("houseId") String houseId);

    HouseInVo getVoById(@Param("id")String id);

    List<HouseInVo> listVoByIds(@Param("ids")List<String> ids);


    List<HouseInVo> listVoByHouseWaitIn(@Param("houseWaitInId")String houseWaitInId);


    Long countByLinkId(@Param("linkId")String linkId);
}
